package com.dc.spring.beanlife;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class configBean {

    @Bean(initMethod = "init",destroyMethod = "destroyMethod")
    public  PersonBean personBean(){
        PersonBean personBean = new PersonBean();
        personBean.setNo(111111);
        personBean.setName("bbbb");
        personBean.setBeanName("ccccccc");
        return personBean;
    }
}
